import React from 'react'
import ReactDOM from 'react-dom'
import { BrowserRouter, useLocation } from 'react-router-dom'
import { ConfigProvider, Button, Switch, message } from 'antd'
import zhCN from 'antd/es/locale/zh_CN'
import moment from 'moment'
import 'moment/locale/zh-cn'
import './index.less'
import { Page } from '../../dist/es'

moment.locale('zh-cn')
const validateMessages = {
  required: '${label}不能为空',
  string: {
    min: '${label}至少输入${min}个字符',
    max: '${label}最多可输入${max}个字符'
  }
}

const App = () => <Page />

ReactDOM.render(
  <ConfigProvider locale={zhCN} form={{ validateMessages }}>
    <App />
  </ConfigProvider>,
  document.getElementById('app')
)
